<!-- 上拉加载下拉更新 -->
<template>
	<scroll-view 
	:upper-threshold="threshold"
	 scroll-y="true" class="scroll-Y h100 " 
	 refresher-enabled
	 refresher-background="#f8f8f8"
	 @refresherrefresh="onRefresh"
	 @refresherrestore="onRestore"
	 @scrolltolower="scrolltolower"
	 :refresher-triggered="triggered">
		<uni-list>
			<uni-list-item
			 v-for="sd in ssdre" 
			 title="列表左侧带略缩图" 
			 note="列表描述信息"
			  thumb="https://img-cdn-qiniu.dcloud.net.cn/new-page/uni.png"
			 thumb-size="lg" />
		</uni-list>
		<view class="kjnjsert">
			<uni-load-more :status="status" ></uni-load-more>
		</view>
	</scroll-view>
</template>
<script>
	export default {
		data() {
			return {
				triggered: true,
				_freshing: false,
				threshold: 100,
				isged:false,
				ssdre:20,
				status: 'more' //  1。more 2。loading 3。noMore 
			}
		},
		components: {},
		methods: {
			onRefresh() {
				if (this._freshing) return;
				this._freshing = true;
				setTimeout(() => {
					this.triggered = false;
					this._freshing = false;
				}, 3000)
			},
			onRestore() {
				this.triggered = 'restore'; // 需要重置
				console.log("onRestore");
			},
			// 滚动到底部触发
			scrolltolower(e){
				this.status = 'loading'
				setTimeout(a=>{
					this.ssdre+=10
					this.status = 'more'
				},2000)
			}
		},
		mounted() {}
	}
</script>
<style scoped>

</style>
